package cn.example.web.base;

import com.jfinal.core.Controller;
import org.artifact.core.lang.ResultData;

public class AbstractController extends Controller {
	
	public void renderSuccess(Object data) {
		renderJson(new ResultData().setData(data));
	}
	
	public void renderError(int errorCode, String description) {
		renderJson(new ResultData().setStatus(errorCode).setDes(description));
	}
}
